<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<!-- ////////////////////////////////////////////////////////////////////
//        *********请尊重我的劳动成果,添加我的著作权*******                                                
//               CreatData: 2017-5-11                            
//               Java Web /:期末作业                            
//               Project: 宿舍管理系统                          
//               软件学院：  学号 ：16171201041                 
//               版权所有：http://allday.gq                     
//               官方邮箱：562015969@qq.com                    
///////////////////////////////////////////////////////////////////// -->










<html xmlns="http://www.w3.org/1999/xhtml">
  
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <link rel="stylesheet" href="./layui/css/layui.css" media="all">
    <link rel="stylesheet" href="./layui/css/cloud.css" media="all">
    <link href="layui/css/main.css" rel="stylesheet" type="text/css" />
    <style type="text/css">#register { float: none; height: 500px; width: 600px; margin-right: auto; margin-left: auto; margin-top: 100px; border-top-style: dashed; border-right-style: dashed; border-bottom-style: dashed; border-left-style: dashed; border-top-color: #000; }</style>
    <script src="./layui/layui.js" charset="utf-8"></script>
    <title>老师|宿舍管理系统-注册界面|Dormitory Management System-REGISTER</title></head>
  
  <body>
    <div class="layui-main">
      <ul class="layui-nav">
        <center>
          <li class="layui-nav-item">
            <a href="./">首页</a></li>
          <li class="layui-nav-item  layui-this">
            <a href="javascript:;">
              <i class="layui-icon">&#xe623;</i>登录/注册</a>
            <dl class="layui-nav-child">
              <dd>
                <a href="login.html">登录</a></dd>
              <dd class="layui-this">
                <a href="register.html">注册</a></dd>
            </dl>
          </li>
          <li class="layui-nav-item">
            <a href="http://allday.gq/about.html" target="_blank">
              <i class="layui-icon">&#xe60b;</i>关于</a></li>
          <li class="layui-nav-item" onclick="disable">
            <i class="cloud"></i>
          </li>
        </center>
      </ul>
    </div>
    <div id="register">
      <center>
        <font face="楷体" size="+2" color="#FFFFFF">Dear Sir/Madam.方便快捷Easy and Convenient</font></center>
      <div id="page-login">
        <form class="layui-form" action="">
          <div class="layui-form-item">
            <input type="hidden" name="teacher" value="true" />
            <label class="layui-form-label">姓名</label>
            <div class="layui-input-inline">
              <input type="text" name="teacher_name" lay-verify="title" autocomplete="off" placeholder="请输入你的名字" class="layui-input"></div>
          </div>
          <div class="layui-form-item">
            <label class="layui-form-label">工号</label>
            <div class="layui-input-inline">
              <input type="text" name="teacher_no" lay-verify="required|number" placeholder="请输入您的工号" autocomplete="off" class="layui-input"></div>
          </div>
          <div class="layui-form-item">
            <label class="layui-form-label">验证日期</label>
            <div class="layui-input-inline">
              <input type="text" name="teacher_date" id="date" lay-verify="date" placeholder="yyyy-mm-dd" autocomplete="off" class="layui-input" onclick="layui.laydate({elem: this})"></div>
          </div>
          <div class="layui-form-item">
            <label class="layui-form-label">密码</label>
            <div class="layui-input-inline">
              <input type="password" name="password" lay-verify="pass" placeholder="请输入密码" autocomplete="off" class="layui-input"></div>
            <div class="layui-form-mid layui-word-aux">请填写6到12位密码</div></div>
          <div class="layui-form-item">
            <label class="layui-form-label">校区-学院</label>
            <div class="layui-input-inline">
              <select name="xiaoqu" lay-verify="required">
                <option value="" selected="">请选择校区</option>
                <option value="1">浙江省</option>
                <option value="2">江西省</option>
                <option value="3">福建省</option></select>
            </div>
            <div class="layui-input-inline">
              <select name="xueyuan" lay-verify="required">
                <option value="">请选择学院</option>
                <option value="杭州">杭州</option>
                <option value="宁波" disabled="">宁波</option>
                <option value="温州">温州</option>
                <option value="温州">台州</option>
                <option value="温州">绍兴</option></select>
            </div>
          </div>
          <div class="layui-form-item">
            <label class="layui-form-label">注册为</label>
            <div class="layui-input-block">
              <a href="register.html" target="_self">学生点这里注册</a>
              <input type="checkbox" name="student" title="学生" disabled="disabled">
              <input type="checkbox" name="teacher_1" title="教师" checked="" lay-verify="required"></div>
          </div>
          <div class="layui-form-item">
            <label class="layui-form-label">性别</label>
            <div class="layui-input-block">
              <input type="radio" name="sex" value="male" title="男" checked="">
              <input type="radio" name="sex" value="female" title="女"></div>
          </div>
          <div class="layui-form-item">
            <div class="layui-input-block">已经有账号咯?
              <a href="login.html">
                <-登录-></a>
              <button class="layui-btn" lay-submit="" lay-filter="demo1">立即提交</button>
              <button type="reset" class="layui-btn layui-btn-primary">重置</button></form>
        </div>
        </div>
        <script>layui.use(['form', 'layedit', 'laydate', 'element'],
          function() {
            var form = layui.form(),
            layer = layui.layer,
            element = layui.element(),
            layedit = layui.layedit,
            laydate = layui.laydate;

            //自定义验证规则
            form.verify({
              title: function(value) {
                if (value.length < 2) {
                  return '检查姓名是否输入';
                }
              },
              pass: [/(.+){6,12}$/, '密码必须6到12位'],
              content: function(value) {
                layedit.sync(editIndex);
              }
            });

            //监听提交
            form.on('submit(demo1)',
            function(data) {
              layer.msg('注册成功。。', {
                icon: 1
              });
            });

          });</script>
  </body>

</html>